home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Precision Software Appli…tions Silver Collection 4
/
Precision Software Applications Silver Collection Volume 4 (1993).iso
/
stats
/
hepcat08.arj
/
HEPCATJR.DOC
< prev
next >
Wrap
Text File
|
1991-04-17
|
58KB
|
1,302 lines
HEPCAT Junior
(Handy Engineer's and Programmer's CAlculation Tool)
Version 0.8
by Patrick Swayne
ZUG Software Engineer
Zenith Data Systems Users' Group
P. O. Box 217
Benton Harbor, MI 49023-0217
(616) 982-3463
Table of Contents
Introduction to HEPCAT Junior .................... 1
Definitions ...................................... 2
System Requirements .............................. 2
Installing HEPCAT ................................ 2
Activating HEPCAT ................................ 3
Using HEPCAT: A Tutorial ......................... 4
Part 1 -- The HEPCAT Display ................... 4
Part 2 -- Entering Numbers and Commands ........ 5
Part 3 -- Calculations ......................... 9
Part 4 -- Memory and Functions ................. 13
Part 5 -- The ASCII Table ...................... 14
Using HEPSETJR to Make Changes ................... 14
Special Considerations for Certain Programs ...... 16
Graphic Video Modes ............................ 17
Sluggish Performance ........................... 17
HEPCAT and Other Pop-Ups ....................... 17
Changing the Activation Key ...................... 18
Removing HEPCAT From Memory ...................... 19
Table of HEPCAT Operations, Functions, and
Commands .................... Separate File
Distribution
These copyrighted programs are provided free of charge. They may
be distributed freely as long as no charge is made for the pro-
grams themselves, or any software package with which they are
included. The programs and all related documentation files must
be distributed together, and may not be modified. A nominal
charge may be made for the disk containing these programs.
Warranty
The programs included herewith are provided AS IS without any
warranty, expressed or implied, including but not limited to
fitness for a particular purpose.
Disclaimer
In no event will the Zenith Data Systems Users' Group or Patrick
Swayne be liable to you for any damages, including any lost prof-
its, lost savings, or other incidental or consequential damages
arising out of the use of or inability to use these programs,
even if the Zenith Data Systems Users' Group or Patrick Swayne
have been advised of the possibility of such damages, or for any
claim by any other party.
Instruction Manual for
HEPCAT (tm) Junior
Introduction to HEPCAT Junior
HEPCAT is an acronym for Handy Engineer's and Programmer's CAlcu-
lation Tool. HEPCAT is a memory resident program, which means
that it installs itself into your computer's memory when you run
it, and remains there ready for use at any time, even while you
are running other programs. When you enter a special activation
key sequence, the HEPCAT display window pops up on your screen,
and HEPCAT takes over the keyboard, so that you can enter calcu-
lations and see them displayed on the HEPCAT window.
HEPCAT Junior is an introductory version of HEPCAT. It can
perform all of the same calculations (except conversions) as its
"big brother". However, the full version of HEPCAT offers some
unique features found in no other pop-up calculator:
1. The full version of HEPCAT is concurrent. That means that
when you pop it up over a running program, the program continues
to run. If you pop it up over Lotus 1-2-3 (tm) while it is
calculating a large spread sheet, Lotus will continue to work
while you use HEPCAT. HEPCAT Junior is not concurrent, and the
program you pop it up over will "freeze" while it is popped up.
2. The full version of HEPCAT can protect the keyboard inter-
rupt it uses to detect its activation key from being "clobbered"
by an application program. This feature allows it to pop up over
"difficult" programs that other pop-ups cannot work with. HEPCAT
Junior does not protect the keyboard interrupt.
3. The full version HEPCAT can be set in a special mode that
will allow it to pop up over Microsoft Windows (tm) version 3
(and Windows applications), even when it is running in the stand-
ard (286) or 386 enhanced modes. We know of no other DOS pop-up
utility that can pop up over Windows 3 in these modes. HEPCAT
Junior cannot pop up over Windows.
4. The full version of HEPCAT can pop up while your computer is
in any standard CGA, EGA, VGA, or Hercules (tm) graphic video
mode, as will as when it is in text modes. You can pop it up
over Windows or AutoCAD (tm) while they are running in EGA or VGA
graphic modes. The graphic screen is not altered, and the part
of the screen under the HEPCAT window is restored when you exit
from HEPCAT. HEPCAT Junior can only pop up while your computer
is in a text mode or a CGA graphic mode.
5. The full version of HEPCAT can perform the following conver-
sions: degrees -- radians, Celcius -- Fahrenheit, centimeters --
inches, meters -- feet, kilometers -- miles, grams -- ounces,
kilograms -- pounds, milliliters -- fluid ounces, liters --
1
quarts. Each conversion works both ways. In other words, you
can convert feet to meters or meters to feet, etc.
If you would like to purchase the full version of HEPCAT, it is
available for $38.50 ($35 plus 3.50 s/h) from
2
Zenith Data Systems Users' Group
P. O. Box 217
Benton Harbor, MI 49023-0217
Ask for ZUG part no. 885-3045-37 if you need a 5.25" disk, or
885-3045-80 if you need a 3.5" disk. Phone orders are accepted
using Visa, Master Card, or American Express. The number is 616-
982-3463.
HEPCAT Junior (hereafter referred to as HEPCAT) is actually two
calculators in one: an engineer's floating point calculator with
several built-in functions, and a programmer's binary calculator
that works in several radixes and has a built-in ASCII table.
The HEPCAT package also includes a parameter setting program that
lets you alter certain parameters of HEPCAT, such as the display
colors in the window.
Definitions
Within this manual, the term PC-compatible will be used to de-
scribe any computer that is compatible with an IBM PC (tm),
including all current Heath or Zenith Data Systems models. The
term Z-100 will be used to describe the discontinued Heath H-100
and ET-100 (with ETA-100 expansion) or Zenith Data Systems Z-100
dual processor series computers.
The term system disk refers to the disk that is used to start up
MS-DOS (or PC-DOS) when you have first turned on your computer or
reset it. if you have a hard disk in your computer, it will
probably be the system disk.
You should be familiar with general MS-DOS usage before you begin
to use this or any other program. Consult your MS-DOS manual if
you do not understand terms like PATH or AUTOEXEC.
Programs like HEPCAT that remain resident in memory are often
called "background programs", but in this manual I will sometimes
refer to HEPCAT as being in the foreground while it is popped up,
and to the program over which it is popped up as being in the
background.
System Requirements
To use HEPCAT, you need a PC-compatible or Z-100 computer, any
version of MS-DOS or Z-DOS, and at least 128k of program memory.
HEPCAT itself uses about 12k of memory on either a PC-compatible
or a Z-100.
Installing HEPCAT
To install HEPCAT, just copy the files HEPCATJR.COM and
HEPSETJR.COM from this package to your system disk. If you have
3
a hard disk, place the files in your root directory, or a direc-
tory pointed to by your PATH statement. If you have a Z-100
computer, copy the file ZHEPJR.COM instead of HEPCATJR.COM, and
rename it to HEPCATJR.COM after you copy it.
If you want HEPCAT to be loaded into memory automatically every
time you boot up your computer, add a line
HEPCATJR
to your AUTOEXEC.BAT file.
After you copy the HEPCAT program files to your system disk,
HEPCAT will be ready for you to load into memory and use. If
added an AUTOEXEC.BAT command to load HEPCAT, reset and reboot
your computer, and HEPCAT will be loaded into memory for you. To
load HEPCAT manually, ensure that you are logged on to your
system disk, and enter
HEPCATJR
at the system prompt, and hit Return.
If you do not wish to make HEPCAT resident in memory this time
but would just like to try it out, you can run it in a special
test mode. To do this, enter
HEPCATJR TEST
at the system prompt, and press Return. The HEPCAT display will
appear in the upper right corner of your screen, and you will be
able to perform all calculations that you can when HEPCAT is
installed normally. You can perform many of the tutorial exer-
cises in this manual with HEPCAT in the test mode. To exit from
the test mode, press the Escape key. Note: Once HEPCAT has been
loaded and is resident in your computer's memory, you cannot use
the test mode.
Activating HEPCAT
Once you have loaded HEPCAT into your computer's memory, you can
activate it at any time by pressing a special activation key
sequence. To active (or "pop up") HEPCAT on a PC-compatible com-
puter, press and release the right Shift key three times. To
activate it on a Z-100 computer, press the Break key twice.
(Note: A procedure to change the activation key is presented
later in this document, but it is not recommended that you do it,
especially in the case of the Z-100 version of HEPCAT.)
When you enter the activation key sequence, the HEPCAT display
window will appear in the upper right corner of your screen when
you activate it, and it will look like this:
4
HEPCATjr version 0.8 by PS 0
D/R: D Rad: F Acc: X Op: CLR
If the display is hard to see on your screen, you may want to
change the display colors. A utility called HEPSETJR has been
provided to allow you to do that and make other changes. HEP-
SETJR is described in the section "Using HEPSETJR to Make
Changes" later in this document.
You can pop up HEPCAT while you are running many different pro-
grams on your computer. For now, however, you should confine
yourself to popping up HEPCAT over the DOS only (that is, while
the system prompt is showing) until you have read this manual
completely.
You can release control from HEPCAT to the currently running
program in two ways. You can release control entirely, remove
the HEPCAT display, and restore the original background display,
by pressing the Escape key. You can also release control but
leave the HEPCAT display on the screen by pressing the F1 key.
Using HEPCAT: A Tutorial
This section of the manual is a tutorial on how to use HEPCAT.
It is assumed that HEPCAT has been installed on your system disk
and is loaded into memory and ready to use. You will be
instructed to enter numbers and commands, and the display changes
that result will be indicated. From time to time rules of
operation will be presented that describe what HEPCAT does in a
certain situation.
Note: If you are using TYPE HEPCATJR.DOC | MORE to view this
file, you should exit from TYPE now (type Ctrl-C), load HEPCAT
into memory, and start TYPEing this file again. Then you can pop
up HEPCAT and try each example as you read the file.
Part 1 -- The HEPCAT Display
Enter the activation key sequence for your version of HEPCAT. The
display window will appear in the upper right corner of your
screen, one line down from the top of the screen. The display is
down one line to allow room for the ZUG screen clock, an accesso-
ry included with the full version of HEPCAT. If you chose not to
include the screen clock, you may want to move the display window
up to the top line. The section on "Using HEPSETJR" will de-
scribe how to do that.
On the top line of the window, you will see the message "HEPCATjr
version 0.8 by PS", and a zero. This line is where numbers you
enter into HEPCAT are displayed, as well as the answers it calcu-
lates. At the left end of the line, the names of built-in func-
tions that you use will be displayed. For example, if you take
the square root of a number, SQRT will be displayed.
5
On the next line, four prompts are displayed. The first prompt
at the left end is "D/R:". There will be a D after this prompt
if the calculator is set to use degrees for angle measurement, or
an R if it is set to use Radians. It is initially set to de-
grees. To change this setting, press the D key. Try it now and
watch what happens. Make sure that the prompt shows D before you
go on.
The next prompt on the second line is "Rad:". Here, the current
radix or floating point display mode is displayed. HEPCAT starts
out in the floating point mode, with a normal floating point
display, which is indicated by the F besides the prompt. We will
show you how to change this later.
The next prompt is "Acc:". This shows you which of the two
accumulators in HEPCAT, X and Y, is displayed on the top line.
The number displayed on the top line is always the content of one
of the accumulators.
The next prompt is "Op:". It indicates the operation that HEPCAT
is commanded to perform. For example, if you are going to add
two numbers, a + will be shown here when you press the + key. At
first the display shows CLR, because no operation has been en-
tered.
Part 2 -- Entering Numbers and Commands
You can enter numbers into HEPCAT using either the numerical
keypad or the main keyboard. On PC-compatible computers, it does
not matter what the setting of Num Lock is while HEPCAT is popped
up. The keys on the keypad will always produce numbers when they
are pressed without a Shift key down (except in the ASCII table
mode, described later). When you hold down a Shift key, the
numbered keys on the keypad will always perform other functions
(arrow keys, etc.). While HEPCAT is active, you can use either
the left or right Shift key or the Alt key for shifted functions.
The Caps Lock key also has no effect while HEPCAT has control.
For example, the built-in function that calculates the sine of an
angle is always activated by pressing the S key, and the arc sine
function is always activated by pressing Shift-S (or Alt-S).
If you have a keyboard with separate arrow keys (separate from
the numerical keypad) on your PC-compatible computer, you can use
those arrow keys without having to hold down a shift key.
On a Z-100 computer, you should release the Caps Lock key if it
is down while you are using HEPCAT, because it does make a dif-
ference on how the main keyboard is interpreted. If you type S
while the Caps Lock key is down, the arc sine function will be
performed regardless of whether you held down a Shift key or not.
When you need to use an arrow key on the Z-100, you can either
use the separate marked arrow keys by themselves (no Shift
needed), or you can hold down a Shift key and use the 2, 4, 6, or
8 keys.
6
In the following exercises, when you are instructed to press an
arrow key, you should hold down either Shift key or the Alt key
if your computer is a PC-compatible that does not have separate
arrow keys. You can use the separate marked arrow keys if your
computer is a Z-100, or you can hold down a Shift key and use the
2, 4, 6 or 8 keys of the keypad.
Here are some exercises to familiarize you with entering numbers
and commands in HEPCAT. If you have already been playing with
it, press the Back Space key until "CLR" appears after the "Op:"
prompt in the lower right corner of the window.
Type the numbers 1, 2, and 3. If this is the first time you have
entered any numbers, you will see the message "HEPCATjr version
0.8 by PS" disappear as soon as you type the first number. The
display should now look like this:
123
D/R: D Rad: F Acc: X Op: CLR
Now press the Back Space key three times. Notice that the
numbers are removed from the display in the reverse order as you
typed them. Now type 123 again, and press the up arrow key. The
display should look like this:
1.2300000 E+02
D/R: D Rad: S Acc: X Op: CLR
You have changed to the scientific notation mode, in which
numbers are always displayed as a mantissa and exponent. Now
press the up arrow again. The display should look like this:
123.00000 E+00
D/R: D Rad: E Acc: X Op: CLR
This is the engineering notation mode. It is like the scientific
notation mode except that the exponent is always forced to a
multiple of 3. Now press the down arrow key three times. You
will go back through the scientific and normal floating point
modes, and wind up at a display that looks like this:
123.00
D/R: D Rad: F2 Acc: X Op: CLR
This is the fixed point mode, and the "F2" after the "Rad:"
prompt shows the number of places after the decimal. Press the
left arrow key 6 times, and the display should look like this:
123.00000000
D/R: D Rad: F8 Acc: X Op: CLR
You can set the number of places after the decimal to any value
from 2 to 8 using the left or right arrow keys. If you try to go
beyond these limits, nothing will happen. Press the left arrow
key again and notice that the display remains at 8 places after
7
the decimal. Leave the decimal places set to 8, and press the
down arrow key. The display will look like this:
7B
D/R: D Rad: 16 Acc: X Op: CLR
You have just switched from the floating point calculator to the
binary calculator, and set the radix to base 16 (hexadecimal).
Notice that the number 123 (decimal) is automatically converted
to its hexadecimal equivalent. Press the down arrow key 8 more
times, noticing what happens each time. You will see the 6
radixes that the binary calculator supports (hexadecimal, dec-
imal, split octal, octal, tetral (base 4), and binary). At the
sixth press of the down arrow key, HEPCAT will reenter the float-
ing point calculator and switch to the engineering notation mode.
After the eighth press, the display should look like this:
123
D/R: D Rad: F Acc: X Op: CLR
You are back at the normal floating point display. Now press the
Back Space key once. This time, the entire number disappears
with only one press.
Back Space rule no. 1: If a number on the display is the result
of your entry, Back Space will remove it one digit for each key
press. If the number is the result of something HEPCAT has done,
one press of Back Space will remove the entire number.
Now try to enter 123456789. The display will look like this:
12345678
D/R: D Rad: F Acc: X Op: CLR
The floating point calculator only allows 8 significant digits.
When you tried to enter the 9, it wasn't accepted. Now type a 0,
and the display should look like this:
1.2345678 E+08
D/R: D Rad: F Acc: X Op: CLR
Even though the calculator only allows 8 significant digits, it
will allow you to enter zeros after the 8th digit to make the
number larger. Since the display cannot show more than 8 digits
in this mode, it automatically changes to scientific notation to
show the large number. Now press the down arrow key, and the
display should look like this:
OVER
D/R: D Rad: F8 Acc: X Op: CLR
The fixed point display can only show a maximum of 16 digits.
Since it is set to show 8 places after the decimal, it is not
able to show the 9-digit number that is now in the accumulator.
Press the right arrow key once, and you should have:
8
123456780.0000000
D/R: D Rad: F7 Acc: X Op: CLR
Now the number can be displayed within the limits allowed. You
should be aware that even though the calculator can show a number
of more than 8 digits in this mode, it still can handle only 8
significant digits. Press the Back Space key to clear the dis-
play, and the up arrow key to return to the normal floating point
mode.
Enter the number 1.2345678 and try to enter an additional 0.
Since trailing zeros on a decimal number do not affect the value
of the number, they are not allowed. Press the Back Space key
until the number is cleared back to zero. Now, enter .012345678,
and the entire number will be accepted. Zeros that fall between
the decimal point and the first significant digit are not them-
selves significant, but change the value of the number, so they
are allowed. Again, press the back space key until the number is
cleared to zero.
Enter the number 123E23. The display should now look like this:
1.2300000 E+25
D/R: D Rad: F Acc: X Op: CLR
You can enter numbers containing exponents directly, but if they
are not in standard scientific format, they will be converted as
you enter them. Therefore, when you entered 123E23, which means
123 E+23, it was translated to 1.23 E+25. It is not necessary to
type the + key after the E if the exponent is positive, but you
must type a - if the exponent is negative. Now press the space
bar, and the display should show:
-1.2300000 E+25
D/R: D Rad: F Acc: X Op: CLR
The space bar is used to change the sign of the number on the
display. The - key is used only for entering negative exponents,
and for subtraction.
Press the down arrow key 4 times. You should now be in the split
octal radix of the binary mode. The display will show zero,
because the floating point number was too large to convert to
binary (32 bits). Type an 8, and notice that nothing happens.
HEPCAT will not allow you to enter a digit not in the current
radix. Only 0-7 are allowed in octal. Now type 737. The dis-
play shows:
337
D/R: D Rad: 8S Acc: X Op: CLR
In the split octal radix, only 0-3 is allowed in every third
place, and so the 7 is truncated to a 3. But suppose that the
number that the number we intended to type was 7377, which is a
legal split octal number. Go ahead and type one more 7. The
9
display will now show:
007 377
D/R: D Rad: 8S Acc: X Op: CLR
Now the four digits that we entered, 7377, are shown correctly.
(Notice that HEPCAT leaves a space between each byte in the split
octal radix.) The first 7 entered was truncated when it fell
into the third place, but it was restored when the final digit
was entered. Keep this in mind when you enter split octal num-
bers. It may not appear correctly on the display until you have
entered the complete number. However, whether the number you
entered is legal or illegal (and truncated), the number shown on
the display will be the one used in calculations.
Now press the up arrow key twice, and press the space bar. Be-
fore you pressed the space bar, the number in the display was
7FF, which is the hexadecimal equivalent of 3733 in split octal.
After you press the space bar, the display shows:
FFFF F801
D/R: D Rad: 8S Acc: X Op: CLR
This is the two's complement of 7FF. When you negate a number in
a non-decimal radix, the two's complement will be shown. If you
want to, use the arrow keys to see what this number looks like in
the other radixes and display modes, and then go to the normal
floating point (Rad: F) mode and press Back Space to clear the
number to zero in preparation for the next section.
Part 3 -- Calculations
Ensure that HEPCAT is set to the floating point display mode and
that it is cleared. The number on the top line should be 0, and
the operation prompt should show CLR. Now without holding down a
shift key, press the +/= key on the main keyboard. Notice that
the operation changes to +. While HEPCAT has control, the +/=
key produces + whether you use a shift key or not. So what does
HEPCAT use for an equal key? We'll get to that a bit later. Now
press the - key that is right next to the +/= key, and the
operation will change to -. If you have a PC-compatible, press
the keypad + key (at the right edge of the keyboard). If you
have a Z-100, press the keypad Enter key. The display should
show + at the operation prompt. On a Z-100, the keypad Enter key
is a + key while HEPCAT has control. Now, press the keypad -
key, and the operation prompt should show - again.
How hold down a Shift key (don't forget that you can use Alt for
a shift key on PC-compatibles) and press the keypad + key (keypad
Enter key on a Z-100). Notice that the operation prompt now
shows *. Hold down a Shift key again, and press the keypad -
key. The operation prompt should now be /. You can perform the
four basic math operations, +, -, *, and /, all from the keypad
with HEPCAT by using Shift-plus (Shift-Enter on a Z-100) for
multiplication and Shift-minus for division.
10
If you have a PC-compatible, press the Prt Sc key, and the opera-
tion prompt will show *. On either computer type, press the \
key, and the prompt will show /. It should be obvious by now
that there several keys you can use for the four basic math
operations. For +, you can use the +/= key or the keypad +
(keypad Enter) key. For -, you can use the main keyboard - key
or the keypad - key. For *, you can use Shift-8 on the main
keyboard, Shift-plus (Shift-Enter) on the keypad, or the Prt Sc
on PC-compatibles. For /, you can use the main keyboard / key,
the \ key, or shift-minus on the keypad. Of course, if your
keyboard has separate * and / keys on the keypad, you can use
those also.
Note: In the binary mode, you cannot use \ for division. The \
key is used for the modulus operation.
Now press the Back Space key so that CLR shows at the operation
prompt, and then press 2, +, 3, and +. The display should look
like this:
= 5
D/R: D Rad: F Acc: X Op: +
Notice that the answer to 2+3 is displayed, and also that an
equal sign (=) has appeared on the top line. Now press 1 and -,
and the display will show:
= 6
D/R: D Rad: F Acc: X Op: -
The display now shows the answer to 2+3+1, but the operation
prompt now shows a -. Now press 1 and +, and the display will
show:
= 5
D/R: D Rad: F Acc: X Op: +
This is the answer to 2+3+1-1. If what we have done seems a bit
confusing to you right now, consider what happens when you work
with an ordinary (infix notation) pocket calculator. If you key
in 2, +, 3, and +, as soon as you type the second + the calcula-
tor will apply the first + to the two numbers typed in, and
display the result. That is exactly how HEPCAT works! The fact
is that on an ordinary pocket calculator, the = key is not needed
at all. Instead of typing = when you want to get the result of a
calculation entered, you can type any one of the operation keys
(+, -, * or /). Try entering the same sequence into a pocket
calculator that we entered into HEPCAT. Enter 2, +, 3, +, 1, -,
1, +, and see if you don't get exactly the same result that you
got with HEPCAT. But if you don't feel comfortable without an
equal key, just use the +/= key on the main keyboard whenever you
feel that you should press =. You will actually be entering +,
but the result will be the same. You could enter our sample
calculation as 2, +, 3, =, +, 1, =, -, 1, =, on either the pocket
calculator or in HEPCAT, but you will have used two unnecessary
11
keystrokes.
Now press Back Space once, and notice that the number is cleared
to zero, and the operation is cleared to CLR.
Back Space rule no. 2: If the number on the display is the
result of a calculation (as indicated by the = sign on the top
line), one press of the Back Space key will perform a master
clear. That is, the number will be cleared to zero, and the
operation will be cleared to CLR.
Now enter 22+33, and watch closely what happens after each key is
pressed. When you type the 22, only the number display changes.
When you type the +, the operation prompt changes. When you type
the 33, the number display changes to 33, and the accumulator at
the "Acc:" prompt changes to Y.
Accumulator entry rule: Any time you type a number after you
have typed an operation key, that number is placed into the Y
accumulator. At other times, the X accumulator is used.
Now press the Back Space key twice. The number on the display is
cleared to zero. Now, type the - key. The display will look
like this:
22
D/R: D Rad: F Acc: X Op: -
Notice that the operation changed to -, the accumulator changed
back to X, and the number 22 (which is in the X accumulator)
reappeared. Now type 33 again, and watch the accumulator change
back to Y. Use Back Space again, but this time press it three
times. The display will show this:
0
D/R: D Rad: F Acc: X Op: CLR
Back Space rule no. 3: When you clear a number in the Y accumu-
lator to zero using Back Space, you can then enter a new opera-
tion. When you do, the accumulator will switch back to X, and
the display will show the number in the X accumulator. However,
if you press Back Space one more time after clearing the Y accu-
mulator to zero, it will perform a master clear.
Now enter the calculation 22/0= (remember that you can use any
operation key for =). The display will look like this:
ERROR
D/R: D Rad: F Acc: X Op: CLR
Any time you try something that HEPCAT cannot do, such as divi-
sion by zero, it performs a master clear, except that the word
"ERROR" is placed in the display instead of the number zero. You
can either press Back Space to get rid of the ERROR, or you can
just enter a new number. The first digit typed will get rid of
12
the ERROR display.
Enter the keys 1, <, 1, and =. The display will look like this
(assuming you used +/= for the = key):
= 1.4142135 45.000002
D/R: D Rad: F Acc: X Op: +
The "<" that you typed is the operator for rectangular to polar
coordinate conversion. This operation results in two answers,
both of which are displayed. The r value is displayed first, and
is in the X accumulator. The theta value is displayed next, and
is in the Y accumulator. The X accumulator is the one that would
be used in subsequent calculations, so if you were to enter 5, =,
for example, you would be adding 5 to 1.4142135. Suppose you
wanted to use the theta value in the next calculation? You can,
just by typing X. That will cause the values in the X and Y
accumulators to be swapped. Try it now, and the screen will
show:
45.000002
D/R: D Rad: F Acc: X Op: +
The r value simply disappeared, since the HEPCAT has gone back to
the normal display method of showing only the active accumulator
on the screen. The active accumulator is X, which now contains
the theta value instead of the R value it held previously. You
can also type X to swap two values that you have entered yourself
before completing a calculation.
In addition to the special < operator, HEPCAT also supports the #
operator, which performs polar to rectangular conversion. To use
it, enter the r value, the # operator, and the theta value. This
operation also causes two numbers to be displayed. The first
number is the X value, which will be in the X accumulator. The
second number is the Y value, in the Y accumulator.
The two special operations, < and #, along with ^ (X to Y power)
and the standard 4 (+, -, *, and /) make up the operations
available in the floating point calculator. The binary calcula-
tor supports the standard four along with \ (modulus), & (logical
AND), ^ (logical OR), # (logical XOR), L (shift left) and R
(shift right). Included with HEPCAT is a "Table of HEPCAT Opera-
tions, Functions, and Commands" that will list all of these and
other HEPCAT features.
In addition to the L and R operators, HEPCAT provides another
special way to shift a number left or right. To illustrate it,
press the down arrow key twice to change to the binary mode,
hexadecimal radix, and press Back Space to clear the calculator.
Then enter FFFF, and press the left arrow key once. The display
will show:
1 FFFE
D/R: D Rad: 16 Acc: X Op: CLR
13
This is the result of shifting FFFF left by one bit. You can
shift any number right or left while HEPCAT is in the binary mode
just by pressing the right or left arrow keys.
Part 4 -- Memory and Functions
HEPCAT contains 10 memory cells into which you can store the
results of calculations at any time. To access the memory cells,
you type M followed by the cell number and a memory operation
code. The operation codes are S (store), R (recall), C (clear),
X (exchange cell with accumulator), + (add accumulator to cell),
and - (subtract accumulator from cell). The 10 memory cells are
numbered 0 through 9, and if you are accessing memory cell 0, you
can leave off the cell number. To illustrate, enter M, 0, and S,
and then press Back Space to clear the display. Now, enter M,
and R, and the number that was on the display before you cleared
it will reappear. Now press the up arrow key twice to go back to
the normal floating point mode, and press Back Space to clear the
display. Now enter the number 123, and press M, 1, and S. Now,
type M twice, and the screen should show:
M 0B 1F 2C 3C 4C 5C 6C 7C 8C 9C
D/R: D Rad: F Acc: X Op: CLR
Typing M twice calls up a memory map that shows you how each cell
is being used. Each cell is listed by its cell number, followed
by a C if the cell is clear, a B if it holds a binary number, and
an F if it holds a floating point number. In our example, cell 0
has a binary number in it, cell 1 contains a floating point
number, and the other cells are cleared. When you call up the
memory map, you can complete a memory operation by entering a
cell number and operation code, an operation code only for cell
0, or you can just press Back Space to remove the memory map and
restore the previous number. Now type R, and the screen should
show:
131070
D/R: D Rad: F Acc: X Op: CLR
This is the decimal equivalent of 1FFFE, the number that was
stored into cell 0. Whenever you recall a binary number while
you are in the floating point mode, it is converted to floating
point as it is recalled into the active accumulator. This pro-
cess also works the other way (when possible), so that floating
point numbers recalled by the binary calculator are converted to
binary. However, the MX, M+ and M- operations do not work like
this. MX only works if the cell contains the same type of number
as the accumulator, and M+ and M- only work if the cell is either
empty or contains the same type of number as the accumulator.
Type Q, and the display will show:
SQRT 362.0359
D/R: D Rad: F Acc: X Op: CLR
14
You have just taken the square root of 131070. The square root
function is just one of the functions built into HEPCAT. You
will find a list of them in the "Table of HEPCAT Operations,
Functions, and Commands".
Part 5 -- The ASCII Table
Press Back Space to clear the display, press the down arrow key
twice (to switch to radix hexadecimal), and type T. The display
will now switch to the ASCII table display. The organization of
the information in this table will be different depending on the
type of computer you have. If you have a PC compatible, each
entry in the table will show the value of the character in deci-
mal (using 3 digits with leading zeros), the value in hexadeci-
mal, the printable form of the character (which may be either a
graphic symbol or a normal alpha-numeric character), the mnemonic
representation, if any, of the character, and the control desig-
nation, if any, of the character.
On a Z-100, each entry will show the value in decimal (3 digits),
the value in hexadecimal, either the printable form of the char-
acter or the control designation, and either the mnemonic or the
H-19 graphic equivalent. You must have an ALTCHAR.SYS file on
your system disk that defines the H-19 graphic characters in
order for HEPCAT to display them correctly.
You can move around in the ASCII table as follows: Press the
keypad 3 (or Page Down) key to move forward 4 places and the
keypad 9 (or Page Up) key to move backward 4 places. Press the
keypad 8 key (or the separate up arrow if you have one) to move
backward 1 place, or the keypad 2 key (or separate down arrow) to
move forward one place. Try moving around in the table for a
while.
Press the Back Space key once, and the HEPCAT display will revert
to normal. Now enter the number 20, and type T to enter the
ASCII table again. This time, the table will start with 20
(hexadecimal) or 32 (decimal). Any time that you need to see the
ASCII equivalent of a number while you are in the binary calcula-
tor mode, just type T, and the ASCII table will appear, starting
with the number that was on the screen. If the number is larger
than the maximum ASCII value supported (255 on a PC-compatible or
127 on a Z-100), the modulo 256 or 128 value of that number will
be used as the starting point of the table.
This concludes the tutorial on HEPCAT. If you want to, press
Escape now to return HEPCAT to the background, quietly waiting
for its next assignment.
Using HEPSETJR to Make Changes
A program called HEPSETJR is provided with HEPCAT that lets you
change a number of parameters once HEPCAT has been loaded into
memory. When you ran INSTALL, HEPSETJR was automatically copied
15
to your disk. To use it, enter
HEPSETJR xx[,xx,xx,xx...]
where xx is one of the following:
AR Set angle measurement to radians.
AD Set angle measurement to degrees. This is the default
setting.
R2 Set HEPCAT to come up in the binary mode, with the
radix set to binary.
R4 Set the radix to tetral (base 4).
R8 Set the radix to octal.
R8S Set the radix to split octal.
R10 Set the radix to decimal (binary mode).
R16 Set the radix to hexadecimal.
RFn Set the floating point display mode to fix point, with
n places after the decimal. Use 2 to 8 for n.
RF Set the normal floating point mode. This is the de-
fault setting.
RS Set the display mode to scientific notation.
RE Set the display mode to engineering notation.
The above settings will take effect only if HEPSETJR is run
before HEPCAT has been popped up for the first time after you
have loaded it into memory. The following settings can be used
any time.
D Disable HEPCAT. Use this command if you have to run a
program that requires you to repeatedly press the right
shift key (or Break key on a Z-100). HEPCAT will not
pop up while it is disabled.
E Enable HEPCAT. Use this command to turn HEPCAT back on
after you have used HEPSETJR D.
Cfb Set the display colors to the values f and b, where f
is the foreground color value, and b is the background
color value, and f and b are hexadecimal numbers. For
a PC-compatible computer, the acceptable values are:
0 black 4 red 8 dk gray C br red
1 blue 5 magenta 9 br blue D br mag.
2 green 6 brown A br green E yellow
3 cyan 7 gray B br cyan F white
Use only 0-7 for background colors. On a Z-100 comput-
er, the acceptable values are:
0 black 4 green
1 blue 5 cyan
2 red 6 yellow
3 magenta 7 white
On a PC-compatible with a monochrome text display card
or Hercules-compatible monochrome card, the following
foreground and background combinations can be used with
16
the results shown:
70 normal intensity characters on black
07 black characters on a light background
10 underlined characters on black
F0 intense characters on black
10 underlined characters on black
90 intense underlined characters on black.
The default settings are yellow on red for a PC-compat-
ible with a color card, black on a light back ground
for a PC-compatible with a monochrome text display, and
black on cyan for a Z-100. See the section "Special
Considerations for Certain Programs" for more informa-
tion on colors.
Tn Set the top line of the HEPCAT window to line n, where
n is 0 through 9. The default is 1. On a Z-100, only
0 or 1 can be used.
S Save the current color and top line settings in your
HEPCATJR.COM file. This command will only work if HEP
CATJR.COM is in the default directory on the default
drive, and only if you have MS-DOS 2 or above. The
settings are copied from the memory resident HEPCAT to
the HEPCATJR.COM file, so any changes you made since
you loaded HEPCAT will be saved.
You can add a line to your AUTOEXEC.BAT file to cause HEPCAT to
pop up with any of the above settings different from the
defaults. For example, if you wanted it to come up with angle
measurement set to radians, the display mode set to scientific
notation, and the display colors set to white on a red background
(for a PC-compatible), the HEPSETJR command would be:
HEPSETJR AR,RS,CF4
With the above line added to your AUTOEXEC.BAT file (after the
HEPCAT line), HEPCAT will pop up with the new settings. See
"Modifying Your AUTOEXEC.BAT".
Note: Since the AD and RF settings are the default, and since
the angle measurement and radix can only be changed with HEPSETJR
before HEPCAT has been popped up, these settings actually do
nothing. They were added to HEPSETJR in case the defaults change
in a future version.
After you enter a valid HEPSETJR command it will display the cur-
rent settings for some of the settable parameters like this:
HEPCAT is enabled.
FG Color=E, BG Color=4, Top Row=1
If you want to see the settings without changing anything, enter
HEPSETJR ?. If you enter an invalid command in the HEPSETJR
command line, or if you run HEPSETJR with no argument, it will
display a help screen listing the available settings.
17
Special Considerations for Certain Programs
HEPCAT was designed so that it can be popped up over a greater
variety of programs than many other pop-up utilities (even HEPCAT
Junior). Here are some things you are likely to encounter be-
cause of this.
Graphic Video Modes
The following discussion applies only to PC-compatible computers.
The colors mentioned previously in the discussion about HEPSETJR
are valid only for the normal text modes of CGA, EGA and VGA
video displays. If the computer is in the CGA four color graphic
mode, the colors in the HEPCAT display will be different. The
background color will always be either black or the color of the
existing background, so you should not set the foreground color
to black if you expect to use HEPCAT while the display is in a
graphic mode. The color of the characters in the HEPCAT window
will be determined by the last two bits in the color's numerical
value, as shown in the following chart:
Bits Palette 0 colors Palette 1 colors
01 green cyan
10 red magenta
11 yellow white
Therefore, you should avoid using a black, red, dark gray, or
bright red as a foreground color if you want to be able to see
the HEPCAT display while it is popped up during a CGA four color
graphic mode.
Sluggish Performance
HEPCAT is designed to work as safely as possible, no matter what
the program you try to popped it up over is doing. If it detects
that a DOS function call (other than keyboard input) is in
progress while it is trying to respond to the pop-up command, it
will wait until the DOS call is finished before popping up. That
is what makes it safe to use HEPCAT while your compiler is grind-
ing away at a job, even if there is disk activity. If your
system should appear to be "hung" after you try to pop up HEPCAT,
press the Esc key to cancel the pop-up request.
HEPCAT and Other Pop-Ups
HEPCAT can co-exist with most other pop-up programs that you are
likely to use. You may have to adjust the order in which your
pop-ups are loaded to get all of them to work properly, but it is
usually best to load HEPCAT first.
Some pop-up programs use the BIOS keyboard interrupt (on PC-
compatible computers) to detect their hot key, instead of the
hardware keyboard interrupt as HEPCAT does. These pop-ups cannot
be popped up over as many programs as HEPCAT, and they can some-
18
times interfere with the operation of HEPCAT. This usually hap-
pens if you pop up one of them at the DOS prompt, exit it, and
immediately try to pop up HEPCAT. HEPCAT will not appear, and
the system will seem to be "hung". If this happens, press the
Escape key, then press the Back Space key and try HEPCAT again.
If that does not work, press the Escape key, type a Return (which
does no harm at the DOS promt), and try HEPCAT again. The latest
revision of HEPCAT attempts to prevent this problem, but it still
occurs with the Shareware program Deskteam (tm), and you must
press Return after you exit from it before HEPCAT will pop up.
Usually you will not have any problem if you pop up Deskteam over
an application program (rather than over DOS), exit it, and then
pop up HEPCAT.
Note to Windows 386 users: If you load HEPCAT before you run
Windows 386, you can pop up HEPCAT over non-Windows applications
that you run from Windows in a text video mode.
Changing the Activation Key
You can change the activation key in the PC version of HEPCAT
using DEBUG to make a patch. The pop-up key code is stored in
HEPCAT at address 110 (hex). If you want to change the key, it
is recommended that you use one of the following:
Key Code
Left Shift 2A
Ctrl 1D
Alt 38
The key you select will have to be pressed three times to
activate HEPCAT. Here is an example in which the activation key
is changed to the Alt key.
A>DEBUG HEPCATJR.COM
-E110 38
-W
Writing 33E6 bytes
-Q
The xxxx represents a number that will be different on different
systems. The number of bytes in the "Writing.." statement could
be different.
You can also patch the activation key for the Z-100 version of
HEPCAT (at the same address), but it is not recommended because
the activation key is passed on to the currently running program,
and must be a key that is generally ignored by programs. The
break key is the only one that meets this criteria. If you did
patch the key, the Break key would still have to be used while
programs are running that operate the keyboard in the event
driven (up/down) mode. The Z-100 versions of Microsoft Windows
uses the keyboard in the event driven mode.
19
The keyboard codes are listed in the Keyboard Encoder section of
the Z-100 Series Technical Manual.
Removing HEPCAT From Memory
You can remove HEPCAT from memory after it has been installed by
activating it, and then pressing F4 three times. You should do
this ONLY while the DOS system prompt is showing, and not while
running a program, and ONLY if HEPCAT is the last memory resident
program loaded. Failure to observe these restrictions could
cause a system crash! Removal does not work under Z-DOS or MS-
DOS version 1.
20